ci/rust: Enable `cap-std-apis` in default build, add a no-feature build
authorColin Walters <walters@verbum.org>
Thu, 23 Jun 2022 18:43:55 +0000 (14:43 -0400)
committerColin Walters <walters@verbum.org>
Thu, 23 Jun 2022 18:45:11 +0000 (14:45 -0400)
Our CI was missing coverage of `cap-std-apis`.

.github/workflows/rust.yml

index b9c972e233a5d73a5e43a503013a98474086b436..74e395eeea44877fb043c0629e0b79210a22f202 100644 (file)
@@ -11,7 +11,7 @@ on:
 
 env:
   CARGO_TERM_COLOR: always
-  CARGO_PROJECT_FEATURES: "v2021_5"
+  CARGO_PROJECT_FEATURES: "v2021_5,cap-std-apis"
   # TODO: Automatically query this from the C side
   LATEST_LIBOSTREE: "v2022_5"
   # Minimum supported Rust version (MSRV)
@@ -49,6 +49,17 @@ jobs:
         uses: Swatinem/rust-cache@ce325b60658c1b38465c06cc965b79baf32c1e72
       - name: cargo build
         run: cargo build --features=${{ env['CARGO_PROJECT_FEATURES'] }}
+  build-no-features:
+    runs-on: ubuntu-latest
+    container: quay.io/coreos-assembler/fcos-buildroot:testing-devel
+    steps:
+      - uses: actions/checkout@v2
+      - name: Cache Dependencies
+        uses: Swatinem/rust-cache@ce325b60658c1b38465c06cc965b79baf32c1e72
+      - name: Build
+        run: cargo test --no-run
+      - name: Run tests
+        run: cargo test --verbose
   build-git-libostree:
     runs-on: ubuntu-latest
     container: quay.io/coreos-assembler/fcos-buildroot:testing-devel